export default {
 // 设置token
 setToken (state, e) {
  state.token = e;
  return state.token;
 },
 // 设置用户信息
 setInfo (state, e) {
  state.info = e;
  return state.info
 },

 // 第一次进入页面时
 setLoading (state, e) {
  state.loading = e;
  return state.loading
 },

 // 设置语言
 setLang (state, e) {
  state.lang = e;
  return state.lang
 },

 // 设置语言名字
 setLanguage (state, e) {
  state.language = e;
  return state.language
 },

 // 清空储存信息
 clear (state, e) {
  for (let i in state) {
   console.log(i)
   if (i !== 'lang' && i !== 'language') {
    state[i] = ''
   }
  }

  return state
 }
}
